//
//  CubeJumpTool.m
//  Rail
//
//  Created by hychen on 2018/7/18.
//  Copyright © 2018年 Hychen. All rights reserved.
//

#import "CubeJumpTool.h"
#import "WatchVideoViewController.h"
#import "LineManageViewController.h"
#import "CarLogViewController.h"
#import "SelectUserViewController.h"
#import "ObserverLineViewController.h"
#import "HomeAllFunctionController.h"
#import "GetDeviceListViewController.h"
@implementation CubeJumpTool
+ (void)clickCubeButton:(NSInteger)index sign:(NSString *)sign {
    if ([sign isEqualToString:@"videoctrl"]) {
        //视频监控
        WatchVideoViewController *vc = [WatchVideoViewController new];
        [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
    }
    else if ([sign isEqualToString:@"devicectrl"]) {
        //设备管理
        //跳线路管理
        [[self class] goToLineManage];
    }
    else if ([sign isEqualToString:@"carreg"]) {
        //车辆登记
        CarLogViewController *vc = [CarLogViewController new];
        [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
    }
    else if ([sign isEqualToString:@"faceget"]) {
        //人脸采集
        SelectUserViewController *vc = [SelectUserViewController new];
        [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
    }
    else if ([sign isEqualToString:@"linectrl"]) {
        //巡线管理
        ObserverLineViewController *vc = [ObserverLineViewController new];
        [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
    }
    else if ([sign isEqualToString:@"more"]) {
        //更多
        HomeAllFunctionController *vc = [HomeAllFunctionController new];
        [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
    }
    else if ([sign isEqualToString:@"getdevice"]) {
        //设备领用
        GetDeviceListViewController *vc = [GetDeviceListViewController new];
        [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
    }
}

+ (void)goToLineManage {
    LineManageViewController *vc = [LineManageViewController new];
    [[BaseNavigationController rootNavigationController] pushViewController:vc animated:YES];
}
@end
